const express = require("express");
const https = require("https");
const fs = require("fs");
const app = express();
const router = require("./router.js");
const httpOption = {
    key: fs.readFileSync("./2.key"),
    cert: fs.readFileSync("./1.pem")
};
app.use(router);
const cors = require("cors");
app.use(cors());

// app.listen(3332,()=>{
//     console.log("服务器已启动");
// });
https.createServer(httpOption, app).listen(3332, function () {
    console.log("服务器已启动在3332端口");
});